package org.oschina.helper;

import org.oschina.Constants;
import org.oschina.util.AESUtil;
import org.springframework.stereotype.Component;

@Component
public class EncryptHelper {

	/**
	 * 加密
	 * @param content
	 * @return
	 */
	public String encrypt(String content)
	{
		return AESUtil.encrypt(content, Constants.ENCRYPT_KEY);
	}
	
	/**
	 * 解密
	 * @param content
	 * @return
	 */
	public String decrypt(String content)
	{
		return AESUtil.decrypt(content, Constants.ENCRYPT_KEY);
	}
}